<include file="public@header" />
</head>
<body>
	<div class="wrap js-check-wrap">
		<form class="well form-inline" method="post" action="{:url('gift/stars')}">
			姓名:
            <input type="text" class="form-control" name="s_name" value="{$s_name}" placeholder="请输入姓名" style="width:200px;display: inline-block;">
			<input type="submit" class="btn btn-primary" value="搜索" />
			<a class="btn btn-danger" href="{:url('gift/stars')}">清空</a>
		</form>
		<table class="table table-hover table-bordered">
			<thead>
				<tr>
					<th width="10"></th>
					<th width="50">ID</th>
                    <th>姓名</th>
                    <th>关注人数</th>
					<th>直播金额</th>
					<th>分成比例</th>
				</tr>
			</thead>
			<tbody>
				<foreach name="star" item="vo">
					<tr>
						<td>
							<input type="radio" class="js-radio" name="udid" value="{$vo.s_udid}" data-name="{$vo.s_name}">
						</td>
						<td>{$vo.id}</td>
						<td>{$vo.s_name}</td>
						<td>{$vo.s_booked}</td>
						<td>{$vo.s_price/100}元</td>
						<td>{$vo.s_ratio}%</td>
					</tr>
				</foreach>
			</tbody>
		</table>
		<div class="pagination">{$page}</div>
	</div>
	<script src="__STATIC__/js/admin.js"></script>
	<script>
        function confirm() {
            var selectedCategoriesId   = [];
            var selectedCategoriesName = [];
            var selectedCategories     = [];
            $('.js-radio:checked').each(function () {
                var $this = $(this);
                selectedCategoriesId.push($this.val());
                selectedCategoriesName.push($this.data('name'));

                selectedCategories.push({
                    id: $this.val(),
                    name: $this.data('name')
                });
            });

            return {
                selectedCategories: selectedCategories,
                selectedCategoriesId: selectedCategoriesId,
                selectedCategoriesName: selectedCategoriesName
            };
        }
	</script>
</body>
</html>